IF  EXISTS (SELECT * FROM sys.objects WHERE object_id = OBJECT_ID(N'[dbo].[medianamik_NodeRevision]') AND type in (N'U')) 
AND NOT EXISTS (SELECT * FROM INFORMATION_SCHEMA.COLUMNS
WHERE TABLE_NAME = 'medianamik_NodeRevision' AND COLUMN_NAME = 'CreatedBy')
ALTER TABLE [dbo].[medianamik_NodeRevision]
ADD CreatedBy nvarchar(50)